<!-- This comment will put IE 6, 7 and 8 in quirks mode -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>dinic: Fichero Fuente node.h</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javaScript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body onload='searchBox.OnSelectItem(0);'>
<!-- Generado por Doxygen 1.6.3 -->
<script type="text/javascript"><!--
var searchBox = new SearchBox("searchBox", "search",false,'Buscar');
--></script>
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Página&nbsp;principal</span></a></li>
      <li><a href="annotated.html"><span>Estructuras&nbsp;de&nbsp;Datos</span></a></li>
      <li class="current"><a href="files.html"><span>Archivos</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <img id="MSearchSelect" src="search/search.png"
             onmouseover="return searchBox.OnSearchSelectShow()"
             onmouseout="return searchBox.OnSearchSelectHide()"
             alt=""/>
        <input type="text" id="MSearchField" value="Buscar" accesskey="S"
             onfocus="searchBox.OnSearchFieldFocus(true)" 
             onblur="searchBox.OnSearchFieldFocus(false)" 
             onkeyup="searchBox.OnSearchFieldChange(event)"/>
        <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
        </div>
      </li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>Lista&nbsp;de&nbsp;archivos</span></a></li>
      <li><a href="globals.html"><span>Globales</span></a></li>
    </ul>
  </div>
<h1>node.h</h1><a href="node_8h.html">Ir a la documentación de este archivo.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 
<a name="l00005"></a>00005 <span class="preprocessor">#ifndef NODE_H</span>
<a name="l00006"></a>00006 <span class="preprocessor"></span><span class="preprocessor">#define NODE_H</span>
<a name="l00007"></a>00007 <span class="preprocessor"></span>
<a name="l00008"></a>00008 <span class="preprocessor">#include &quot;<a class="code" href="uthash_8h.html" title="&amp;lt; Un hashtable que son todos macros &amp;gt;">uthash.h</a>&quot;</span>
<a name="l00009"></a>00009 <span class="preprocessor">#include &quot;<a class="code" href="plist_8h.html" title="&amp;lt; PList maneja un lista simple de doble entrada de punteros a elementos de cualquier...">plist.h</a>&quot;</span>
<a name="l00010"></a>00010 
<a name="l00024"></a><a class="code" href="structs__node.html">00024</a> <span class="keyword">struct </span><a class="code" href="structs__node.html" title="Esta estructura representa un nodo.">s_node</a>{
<a name="l00025"></a><a class="code" href="structs__node.html#aab4ff9ea19fdcd2912bf33c12dbd9d17">00025</a>     <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="structs__node.html#aab4ff9ea19fdcd2912bf33c12dbd9d17">name</a>;
<a name="l00026"></a><a class="code" href="structs__node.html#ad4aaac7056a991c76d016a253cd51b6e">00026</a>     <span class="keywordtype">bool</span> <a class="code" href="structs__node.html#ad4aaac7056a991c76d016a253cd51b6e">visited</a>;
<a name="l00027"></a><a class="code" href="structs__node.html#ad501987761202d579bb1bc012065d7db">00027</a>     <span class="keywordtype">int</span> <a class="code" href="structs__node.html#ad501987761202d579bb1bc012065d7db">level</a>;
<a name="l00028"></a><a class="code" href="structs__node.html#ac163af15996773dceb46390486cb90e5">00028</a>     <a class="code" href="structplist__s.html">plist_t</a> <a class="code" href="structs__node.html#ac163af15996773dceb46390486cb90e5">neighbours</a>;
<a name="l00029"></a><a class="code" href="structs__node.html#a20c889dd2ad9df4c37c79703559ce003">00029</a>     <span class="keywordtype">int</span> <a class="code" href="structs__node.html#a20c889dd2ad9df4c37c79703559ce003">neighbours_count</a>;
<a name="l00030"></a><a class="code" href="structs__node.html#acc38f3e66f4aa22bb0d2687daba55ccd">00030</a>     <a class="code" href="structUT__hash__handle.html">UT_hash_handle</a> <a class="code" href="structs__node.html#acc38f3e66f4aa22bb0d2687daba55ccd">hh</a>;
<a name="l00031"></a>00031 };
<a name="l00032"></a>00032 
<a name="l00033"></a>00033 <span class="comment">/*Esta estructura es necesaria aca porque es hasheable y sino el </span>
<a name="l00034"></a>00034 <span class="comment">     network no acceder.*/</span>
<a name="l00035"></a>00035 
<a name="l00039"></a><a class="code" href="node_8h.html#a459b35d75156ad8335079fba6aeff369">00039</a> <span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="structs__node.html" title="Esta estructura representa un nodo.">s_node</a> *<a class="code" href="structs__node.html" title="Esta estructura representa un nodo.">node</a>;
<a name="l00040"></a>00040 
<a name="l00046"></a>00046 node <a class="code" href="node_8c.html#aa3d6d1ce334fe1b2eea26436c0be566f" title="Crea un nodo nuevo.">node_create</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="structs__node.html#aab4ff9ea19fdcd2912bf33c12dbd9d17">name</a>);
<a name="l00047"></a>00047 
<a name="l00053"></a>00053 <span class="keywordtype">bool</span> <a class="code" href="node_8c.html#a5f9ad7ae1926420663784104838b1ad4" title="Verifica si un nodo fue visitado o no.">node_visited</a>(node nd);
<a name="l00054"></a>00054 
<a name="l00061"></a>00061 <a class="code" href="structplist__s.html">plist_t</a> <a class="code" href="node_8c.html#afc581a10f51d254aeacee4a748f54535" title="Devuelve una lista con todos los vecinos del nodo.">node_neighbours</a>(node nd);
<a name="l00062"></a>00062 
<a name="l00069"></a>00069 node <a class="code" href="node_8c.html#a6413638407ed01ab78bfe8ea70999a47" title="Destruye el nodo.">node_destroy</a>(node nd);
<a name="l00070"></a>00070 
<a name="l00077"></a>00077 <span class="keywordtype">int</span> <a class="code" href="node_8c.html#a17f445ff838f228ec9b7f6e4d5210cc3" title="Devuelve el nivel al que se encuentra el nodo.">node_get_level</a>(node nd);
<a name="l00078"></a>00078 
<a name="l00079"></a>00079 
<a name="l00086"></a>00086 <span class="keywordtype">void</span> <a class="code" href="node_8c.html#a25cee32d7230aa3bef457127fc1b6b2a" title="Seteamos el nivel del nodo.">node_set_level</a>(node nd, <span class="keywordtype">int</span> <a class="code" href="structs__node.html#ad501987761202d579bb1bc012065d7db">level</a>);
<a name="l00087"></a>00087 
<a name="l00093"></a>00093 <span class="keywordtype">void</span> <a class="code" href="node_8c.html#a863fd4f9386c7879bbef53be13f8e216" title="Marca como visitado el nodo.">node_visit</a>(node nd);
<a name="l00094"></a>00094 
<a name="l00095"></a>00095 
<a name="l00101"></a>00101 <span class="keywordtype">void</span> <a class="code" href="node_8c.html#ae38445d3b5d77ed75dadefe59f7f3216" title="Marca como no visitado el nodo.">node_unvisit</a>(node nd);
<a name="l00102"></a>00102 
<a name="l00103"></a>00103 
<a name="l00110"></a>00110 <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="node_8c.html#aa62758a7729f5dc61262f2500fc23ea2" title="Retorna el nombre del nodo.">node_name</a>(node nd);
<a name="l00111"></a>00111 
<a name="l00124"></a>00124 <span class="keywordtype">void</span> <a class="code" href="node_8c.html#a95f1c78c3e45a2745326ec72c24a6ff0" title="Agrega un vecino a la lista de vecinos del nodo.">node_add_neighbour</a>(node nd, node to, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> capacity,
<a name="l00125"></a>00125                              <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> flow, <span class="keywordtype">int</span> <a class="code" href="structs__node.html#ad501987761202d579bb1bc012065d7db">level</a>, <span class="keywordtype">bool</span> backward);
<a name="l00126"></a>00126 
<a name="l00133"></a>00133 <span class="keywordtype">bool</span> <a class="code" href="node_8c.html#ad1b72b3a3dc9d567b3dd64c4d5ac7309" title="Indica si hay vecinos entre los vecinos del nodo nd.">node_neighbours_fordward</a>(node nd);
<a name="l00134"></a>00134 
<a name="l00141"></a>00141 <span class="keywordtype">void</span> <a class="code" href="node_8c.html#acba8170f60ce10c0ef91499427aa17a0" title="Borro el vecino name de la lista de vecinos del nodo.">node_delete_neighbour</a>(node nd, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="structs__node.html#aab4ff9ea19fdcd2912bf33c12dbd9d17">name</a>);
<a name="l00142"></a>00142 
<a name="l00149"></a>00149 node <a class="code" href="node_8c.html#a9fac5d93018120feb15273f5bb9548db" title="Devuelve el primer nodo que este en los vecinos de nd.">node_get_neighbour</a>(node nd);
<a name="l00150"></a>00150 
<a name="l00151"></a>00151 <span class="preprocessor">#endif</span>
</pre></div></div>
<!--- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&nbsp;</span>Todo</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&nbsp;</span>Estructuras de Datos</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&nbsp;</span>Archivos</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&nbsp;</span>Funciones</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&nbsp;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&nbsp;</span>Tipos definidos</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&nbsp;</span>Definiciones</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<hr class="footer"/><address style="text-align: right;"><small>Generado el Mon Jun 6 20:15:28 2011 para dinic por&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address>
</body>
</html>
